﻿<%@ Page Language="C#" AutoEventWireup="true" validateRequest="false" CodeFile="CourseEdit.aspx.cs" Inherits="main_admin_CourseEdit" %>
<%@ Register TagPrefix="telerik" Namespace="Telerik.QuickStart" Assembly="Telerik.QuickStart" %>
<%@ Register TagPrefix="radU" Namespace="Telerik.WebControls" Assembly="RadUpload.Net2" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head>
    <title>课件管理</title>
    <link href="../../css/style.css" rel="stylesheet" type="text/css" />
    <link href="../../css/base.css" rel="stylesheet" type="text/css" />

    <script src="../../js/base.js" type="text/javascript" charset="utf-8"></script>

    <script src="../../js/singleeditpoint.js" type="text/javascript" charset="utf-8"></script>

    <script src="../../js/validator.js" type="text/javascript" charset="utf-8"></script>

    <script src="../../js/comm.js" type="text/javascript" charset="utf-8"></script>
    
    <script src="../../js/common.js" type="text/javascript" charset="utf-8"></script>
       <script type="text/javascript" src="../../Web_ckeditor_html/ckeditor.js"></script>
    <script type="text/javascript" src="../../Web_ckfinder_html/ckfinder.js"></script>

    <script type="text/javascript">	
        
            function tomodifySave(){
                //清除空格	
                TrimAllitems();       
                ClearErrMsg();        
			    var thisForm=document.forms[0];

                //文件是否上传
			    var up = document.getElementById("upFile");
			    if (up.style.display == "block") {
			        showErrMsg(document.getElementById("upFile"), "请上传课件文件!");
			        return false;
			    }
				
				if( Validator.Validate(thisForm,3)) {　

				    if (document.getElementById("txt_COUTENT").value.length > 200) {
				        showErrMsg(document.getElementById("txt_COUTENT"), "备注不能大于5000字符！");
				        return false;
				    }				   
					return true;
				}
				return false;
			}

			function delfile() {
			    if (confirm("请确认删除课件!")) {
			        var txt_name = document.getElementById("txt_NAME");
			        txt_NAME.value = "";		
			        return true;
			    }
			    return false;
			}

			function btnUpfile() {
			    TrimAllitems();
			    ClearErrMsg();  
			    //文件是否上传
			    var save = document.getElementById("FileUpload1");
			    //alert(save.value);
			    if (save.value=="") {
			        showErrMsg(document.getElementById("upFile"), "请选择文件!");
			        return false;
			    }			   		    
			    return true;
			}
    </script> 
    
</head>
<body>
<form name="form1" method="post" id="form1" runat="server">
<div class="conter_right">
<div class="sfkr"><span>当前位置：</span>课件管理</div>
     <fieldset class="dsadq"><legend style="color:#434449"><span id="page_title" runat="server">课件新增</span></legend>
     <table width="100%" border="0" cellpadding="0" cellspacing="0" class="msels">
     
     <tr>    
         <td align="right" valign="middle">
                         <font color="red">*&nbsp;</font><asp:Label ID="Label1" runat="server" Text="课件上传："></asp:Label>
                    </td>
                    <td align="left" valign="middle" colspan="3">
                    
                     <div  id="showFile" style="display:none" runat="server">
                        <span id="file_name" runat="server"></span>
                         <asp:ImageButton ID="ImageButton1"  OnClientClick="return delfile();" OnClick="btnDelFile_Click" runat="server" ImageUrl="~/images/del.jpg"   style="cursor:hand" alt="删除"/>

                     </div> 
                     
                     <div id="upFile" style="display:block" runat="server">
                        <radu:radprogressmanager id="Radprogressmanager1"  Width="100%" runat="server" Height="10px" />
                        <radu:radprogressarea id="progressArea1" Width="100%"  runat="server"></radu:radprogressarea>                        
                        <asp:FileUpload ID="FileUpload1" runat="server" />
                        <asp:Button ID="btnSave" CssClass="seaal" runat="server" Text="上传" OnClientClick="return btnUpfile();" OnClick="btnSave_Click" />      
                     </div>                 
                    </td>   
     </tr>  

         <tr>     
      <td width="16%" align="right" valign="middle"><asp:Label ID="lbl_NAME" runat="server" Text="课件名称"></asp:Label>：</td>
        <td width="34%" align="left" valign="middle" >
           <asp:TextBox MaxLength="50" CssClass="srjks" ID="txt_NAME" runat="server"  
                dataType="Require" msg="名称不能为空！" Width="282px" ></asp:TextBox>
                                        <asp:Label ID="err_NAME" runat="server"></asp:Label></td>
           
           <td width="16%" align="right" valign="middle">
                        <asp:Label ID="lbl_FOL_ID__FOL_NAME" runat="server" Text="文件夹："></asp:Label>
                    </td>
                    <td width="34%" align="left" valign="middle">
                        <asp:DropDownList ID="ddl_FOL_ID__FOL_NAME" runat="server" CanZhao="FOL_NAME"
                            TiaoJian="" dataType="Require" msg="不能为空" CssClass="saae">
                        </asp:DropDownList>
                        <asp:Label ID="err_FOL_ID__FOL_NAME" runat="server"></asp:Label>
                    </td>     
     </tr>
     
       <tr>    
         <td align="right" valign="middle">
                         <asp:Label ID="lbl_CONTENT_TYPE__CATE_NAME" runat="server" Text="内容类型："></asp:Label>
                    </td>
                    <td align="left" valign="middle">
                      <asp:DropDownList ID="ddl_CONTENT_TYPE__CATE_NAME" runat="server" CanZhao="CATE_NAME"
                            TiaoJian="CATE_TYPE|0|3#DEL_FLG|0|3"    CssClass="saae">
                        </asp:DropDownList>
                        <asp:Label ID="err_CONTENT_TYPE__CATE_NAME" runat="server"></asp:Label>
                    </td> 
                
                    <td align="right" valign="middle">
                         <asp:Label ID="lbl_SUBJECT_TYPE__CATE_NAME" runat="server" Text="科目类型："></asp:Label>
                    </td>
                    <td align="left" valign="middle">
                      <asp:DropDownList ID="ddl_SUBJECT_TYPE__CATE_NAME" runat="server" CanZhao="CATE_NAME"
                            TiaoJian="CATE_TYPE|1|3#DEL_FLG|0|3"    CssClass="saae">
                        </asp:DropDownList>
                        <asp:Label ID="err_SUBJECT_TYPE__CATE_NAME" runat="server"></asp:Label>
                    </td>
     </tr>     
     
     
       <tr>    
         <td align="right" valign="middle">
                         <asp:Label ID="lbl_CLASS_TYPE__CATE_NAME" runat="server" Text="年级类型："></asp:Label>
                    </td>
                    <td align="left" valign="middle">
                      <asp:DropDownList ID="ddl_CLASS_TYPE__CATE_NAME" runat="server" CanZhao="CATE_NAME"
                            TiaoJian="CATE_TYPE|2|3#DEL_FLG|0|3"    CssClass="saae">
                        </asp:DropDownList>
                        <asp:Label ID="err_CLASS_TYPE__CATE_NAME" runat="server"></asp:Label>
                    </td> 
                
                    <td align="right" valign="middle">
                         <asp:Label ID="lbl_ELECTIVE_TYPE__CATE_NAME" runat="server" Text="选修类型："></asp:Label>
                    </td>
                    <td align="left" valign="middle">
                      <asp:DropDownList ID="ddl_ELECTIVE_TYPE__CATE_NAME" runat="server" CanZhao="CATE_NAME"
                            TiaoJian="CATE_TYPE|3|3#DEL_FLG|0|3"    CssClass="saae">
                        </asp:DropDownList>
                        <asp:Label ID="err_ELECTIVE_TYPE__CATE_NAME" runat="server"></asp:Label>
                    </td>
     </tr>  

       <tr>    
         <td align="right" valign="middle">
                         <asp:Label ID="lbl_BOOKS_TYPE__CATE_NAME" runat="server" Text="册别类型："></asp:Label>
                    </td>
                    <td align="left" valign="middle">
                      <asp:DropDownList ID="ddl_BOOKS_TYPE__CATE_NAME" runat="server" CanZhao="CATE_NAME"
                            TiaoJian="CATE_TYPE|4|3#DEL_FLG|0|3"    CssClass="saae">
                        </asp:DropDownList>
                        <asp:Label ID="err_BOOKS_TYPE__CATE_NAME" runat="server"></asp:Label>
                    </td> 
                
                    <td align="right" valign="middle">
                         <asp:Label ID="lbl_VERSION_TYPE__CATE_NAME" runat="server" Text="版本类型："></asp:Label>
                    </td>
                    <td align="left" valign="middle">
                      <asp:DropDownList ID="ddl_VERSION_TYPE__CATE_NAME" runat="server" CanZhao="CATE_NAME"
                            TiaoJian="CATE_TYPE|5|3#DEL_FLG|0|3"    CssClass="saae">
                        </asp:DropDownList>
                        <asp:Label ID="err_VERSION_TYPE__CATE_NAME" runat="server"></asp:Label>
                    </td>
     </tr>  


       <tr>    
         <td align="right" valign="middle">
                         <asp:Label ID="lbl_OTHER_TYPE__CATE_NAME" runat="server" Text="其它类型："></asp:Label>
                    </td>
                    <td align="left" valign="middle">
                      <asp:DropDownList ID="ddl_OTHER_TYPE__CATE_NAME" runat="server" CanZhao="CATE_NAME"
                            TiaoJian="CATE_TYPE|6|3#DEL_FLG|0|3"    CssClass="saae">
                        </asp:DropDownList>
                        <asp:Label ID="err_OTHER_TYPE__CATE_NAME" runat="server"></asp:Label>
                    </td>  
                 
                   <td align="right" valign="middle">
                        <asp:Label ID="lbl_STATE" runat="server" Text="共享状态："></asp:Label>
                    </td>
                    <td align="left" valign="middle">
                        <asp:RadioButtonList ID="ddl_STATE" runat="server" RepeatDirection="Horizontal"   />
                        <asp:Label ID="err_STATE" runat="server"></asp:Label>
                    </td>
     </tr>  
 
     <tr>
      <td width="16%" align="right" valign="middle"><asp:Label ID="lbl_COUTENT" runat="server" Text="课件介绍"></asp:Label>：</td>
        <td width="84%" align="left" valign="middle" colspan="3">
           <asp:textBox  id="txt_COUTENT" runat="server" cols="60" rows="6" BorderColor="#999999" BorderStyle="Solid" BorderWidth="1px" 
                TextMode="MultiLine" Width="488px"></asp:textBox>
                <asp:Label ID="err_COUTENT" runat="server"></asp:Label>
         </td>
     
     </tr>
     </table>
     </fieldset>
     </div>
      <div style="height:15px"></div>
        <div class="nstkaah" align="center" style="width:90%">
        <asp:Button runat="server" Text="保存" CssClass="seaal" ID="queding" ToolTip="保存" 
                                         OnClientClick="return  tomodifySave();"   OnClick="queding_Click" />
                                         <asp:Button runat="server" Text="返回" CssClass="seaal" ID="Button3" ToolTip="返回" OnClick="cmdCancel_Click" />
              </div>
              
	<!--jjjjjjjjjjjjjjjjjjjj页脚部分jjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjj-->
	<div id="footer"></div>
   </form>
</body>
</html>
